package org.totalbeginner.tutorial;

public class Person {
	private String name;
	private int maximumBooks;
	
	public Person(){
		this.name = "Unknown name";
		this.maximumBooks = 3;
	}

	/**
	 * @return the name
	 */
	public String getName() {
		return name;
	}

	/**
	 * @param name the name to set
	 */
	public void setName(String name) {
		this.name = name;
	}

	/**
	 * @return the maximumBooks
	 */
	public int getMaximumBooks() {
		return maximumBooks;
	}

	/**
	 * @param maximumBooks the maximumBooks to set
	 */
	public void setMaximumBooks(int maximumBooks) {
		this.maximumBooks = maximumBooks;
	}
	
	/**
	 * @return the String representation of the object. e.g. name (maximumBooks)
	 */
	public String toString() {
		String toReturn = this.getName() + " (" +this.getMaximumBooks()+")";
		return toReturn;
	}
	 

}
